package com.tom.jmgd.controller;

import com.tom.jmgd.common.HttpClientUtil;
import com.tom.jmgd.core.entity.ResultEntity;
import com.tom.jmgd.core.enums.ResultEnum;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

@RestController
@RequestMapping("/autoGeneral")
public class AutoGeneralController {
    /*
    发红包
     */
    @RequestMapping("/fahongbao")
    public String syncJMGDFactory() {
        String resultStr;
        try {
            Map map = HttpClientUtil.doGet("https://zyxiao.jmgdyf.com/api/pay/start");
            resultStr = map.get("msg").toString();
        }catch (Exception ex){
            return "err";
        }
        return resultStr;
    }
}
